Skip to content

Instantly share code, notes, and snippets.

@jrelo
jrelo / PHP_Exploitation_Code.txt
Created October 21, 2017 21:46
List of PHP Exploitation Code
Command Execution
exec - Returns last line of commands output
passthru - Passes commands output directly to the browser
system - Passes commands output directly to the browser and returns last line
shell_exec - Returns commands output
`` (backticks) - Same as shell_exec()
popen - Opens read or write pipe to process of a command
proc_open - Similar to popen() but greater degree of control
pcntl_exec - Executes a program
@MartinEesmaa
MartinEesmaa / youtube_formats.md
Last active July 3, 2025 05:12 — forked from AgentOak/youtube_formats.md
Youtube Format IDs

Note: This is all almost full YouTube ID informations. Original owner goes to AgentOak, modified version by Martin Eesmaa.

See the credits and also special thanks in below.

Last updated: 30 June 2025

Also known as itag or format codes and way back they could be specified with the fmt parameter (e.g. &fmt=22). Depending on the age and/or popularity of the video, not all formats will be available.

DASH video

@jakub-g
jakub-g / async-defer-module.md
Last active July 3, 2025 05:06
async scripts, defer scripts, module scripts: explainer, comparison, and gotchas

<script> async, defer, async defer, module, nomodule, src, inline - the cheat sheet

With the addition of ES modules, there's now no fewer than 24 ways to load your JS code: (inline|not inline) x (defer|no defer) x (async|no async) x (type=text/javascript | type=module | nomodule) -- and each of them is subtly different.

This document is a comparison of various ways the <script> tags in HTML are processed depending on the attributes set.

If you ever wondered when to use inline <script async type="module"> and when <script nomodule defer src="...">, you're in the good place!

Note that this article is about <script>s inserted in the HTML; the behavior of <script>s inserted at runtime is slightly different - see Deep dive into the murky waters of script loading by Jake Archibald (2013)

@urschrei
urschrei / output_geojson.py
Last active July 3, 2025 05:03
Output a GeoJSON FeatureCollection to file from dict point data input
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
output geojson.py
Created by Stephan HΓΌgel on 2015-02-26
I can *never* remember how to efficiently do this, so I'm making a gist.
This should be easily adaptable to use with LineStrings, Polygons etc by
altering the 'geometry' dict accordingly
@mjkstra
mjkstra / arch_linux_installation_guide.md
Last active July 3, 2025 05:02
A modern, updated installation guide for Arch Linux with BTRFS on an UEFI system
Continent_Name Continent_Code Country_Name Two_Letter_Country_Code Three_Letter_Country_Code Country_Number
Asia AS Afghanistan, Islamic Republic of AF AFG 4
Europe EU Albania, Republic of AL ALB 8
Antarctica AN Antarctica (the territory South of 60 deg S) AQ ATA 10
Africa AF Algeria, People's Democratic Republic of DZ DZA 12
Oceania OC American Samoa AS ASM 16
Europe EU Andorra, Principality of AD AND 20
Africa AF Angola, Republic of AO AGO 24
North America NA Antigua and Barbuda AG ATG 28
Europe EU Azerbaijan, Republic of AZ AZE 31
@Arecsu
Arecsu / lasfm-p-dw.py
Last active July 3, 2025 04:58
Last.fm bulk artist photos downloader
# download every image from an artist profile in last.fm!
# full resolution! and multithreading!
# .webp images and .gifs
# want .jpg images instead of .webp? Search for the .replace('jpg' part in the code and delete that line
# jpg in 2022, can you imagine?
#
# usage:
# $ python3 lastfm-p-dw.py https://www.last.fm/es/music/Yung+Lean/+images
#
# SUBMIT A LINK LIKE THAT ONE without any "?page=1". Just clean as the example.
@MohamedElashri
MohamedElashri / jupyter_tmux.md
Created October 9, 2024 16:40
Running a Long-Running Jupyter Notebook Remotely using tmux

Running a Long-Running Jupyter Notebook Remotely using tmux

Step-by-Step Instructions:

  1. Start tmux Session
    • Connect to your remote server via SSH:
      ssh user@remote-server
  • Start a tmux session to keep your terminal session active even after disconnection:
@Aroniez
Aroniez / kenyan_counties.json
Last active July 3, 2025 04:55
List of kenyan counties and their sub-counties in json format
[
{
"name": "Baringo",
"capital": "Kabarnet",
"code": 30,
"sub_counties": [
"Baringo central",
"Baringo north",
"Baringo south",
"Eldama ravine",
@TheSherlockHomie
TheSherlockHomie / RenewExpiredGPGkey.md
Created January 3, 2021 16:36
Updating expired GPG keys and backing them up πŸ”‘πŸ”πŸ’»

Updating expired GPG keys and their backup πŸ”‘πŸ”πŸ’»

I use a GPG key to sign my git commits.

An error like this one might be a sign of an expired GPG key.

error: gpg failed to sign the data fatal: failed to write commit object